{extend name="A_public:index"/}
<title>{block name="title"}用户管理{/block}</title>
{block name="allinfo"}

	<div class="content-panel">
      <h4><i class="fa fa-angle-right"></i> 用户列表</h4><hr><table class="table table-striped table-advance table-hover" style="margin-bottom: 0px">
        <form action="/user/index" method="get">
          请输入用户关键字: <input type="text" name="name" value="{$k}">&nbsp;<input type="submit" value="查询">
        </form>
          <thead>
          <tr>
              <th><i class="glyphicon glyphicon-th-list"></i> 用户编号</th>
              <th class="hidden-phone"><i class="glyphicon glyphicon-user"></i> 用户名</th>
              <th class="hidden-phone"><i class="glyphicon glyphicon-comment"></i> 邮箱</th>
              <th><i class="glyphicon glyphicon-leaf"></i> 用户权限</th>
              <th><i class="glyphicon glyphicon-random"></i> 用户正常登录</th>
              <th><i class="glyphicon glyphicon-resize-full"></i>操作</th>
          </tr>
          </thead>
          <tbody>
    			{foreach name='info' item='row'}
              	<tr>
                      <td>{$row['id']}</td>
                      <td class="hidden-phone">{$row['username']}</td>
                      <td class="hidden-phone">{$row['email']}</td>
                      {if condition="($row['auth'] == 1) "} 
                        <td>暂未分配</td>
                      {else /}
                        <td>功能未开放</td>

                      {/if}
                      <td>
    						{if condition="($row['status'] == 1) "} 
    							<span class="label label-success label-mini">可登录</span>

    						
    						{else /} 
    							<span class="label label-warning label-mini">禁止登录</span>

    						{/if}


                      </td>
                      <td>
                          <button class="btn btn-primary btn-xs"><a href="/user/edit/id/{$row['id']}"><i class="fa fa-pencil" style="color: white"></i></a></button>
                          <button class="btn btn-danger btn-xs"><a href="/user/del/id/{$row['id']}"><i class="fa fa-trash-o" style="color: white"></i></a></button>
                      </td>
              	</tr>
    			{/foreach}
          </tbody>
      </table>
      <div style="float:right;margin-right: 50px">
        {$info->appends($req)->render()}
      </div>
  </div>



{/block}

